function s = csv2struct(file)
% CSV2STRUCT read csv file into struct s
    warning('off','MATLAB:textscan:UnableToGuessFormat') % switch
                                                         % format
                                                         % warnings off
    tab = readtable(file);
    s = table2struct(tab,'ToScalar',true);
end